﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Sparkle.Hosting;
using ReportLib;

namespace Sparkle.Wpf.Demo.UI.Attributes
{
    public class ReportAttribute : DynamicLinkAttribute , IControlAttribute
    {
        public string FolderName { get; set; }

        public string Title { get; set; }

        public ReportAttribute()
        {
            
        }

        public override string ToString()
        {
            return Title;
        }

        public override IList<object> GetDynamicLinks(object refEntity)
        {
            var retuList = new List<object>
                               {
                                   new ReportSummary {ReportName = "employeeDetails", FolderName = FolderName},
                                   new ReportSummary {ReportName = "Holidays", FolderName = FolderName},
                                   new ReportSummary {ReportName = "Sickness", FolderName = FolderName}
                               };

            return retuList;
        }
    }
}
